package com.sdp.flow.listener;

import java.util.Arrays;

import org.flowable.engine.delegate.DelegateExecution;
import org.flowable.engine.delegate.ExecutionListener;

import com.sdp.flow.utils.FlowConstants;

public class TaskApproveListener implements ExecutionListener {


	private static final long serialVersionUID = 1L;
	
	@Override
	public void notify(DelegateExecution execution) {
		//这里可以是查一些配置确定处理人有哪些
		execution.setVariable(FlowConstants.FLOW_ASSIGN_PERSON_LIST_KEY, Arrays.asList(new String[]{"1"}));
//		String activityId = execution.getCurrentActivityId();
//		String eventName = execution.getEventName();
//		if (activityId.equals("Activity_05vcfia") && eventName.equals("start")) {
//			execution.setVariable(FlowConstants.FLOW_ASSIGN_PERSON_LIST_KEY, Arrays.asList(new String[]{"qcy", "zsp"}));
//		}
		
	}

}
